package com.pengtu.entity.work;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;
import javax.persistence.Table;

import com.pengtu.entity.IdEntity;
import com.pengtu.entity.app.Department;

/**
 * 收文档案
 * 注释见{@link ReceivedArc}.
 * @author libitum
 *
 */
@Entity
@Table(name = "T_ARC_RECEIVED")
public class ReceivedArc extends IdEntity {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private String title;			//来文标题
	private String recipient;		//接收人
	private String approved;		//批办人
	private String undertake;		//承办人
	private String annex;			//附件
	private String remark; 			//备注
	private Department department;	//来文部门
	
	@Column(name="TITLE")
	public String getTitle() {
		return title;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	
	@Column(name="RECIPIENT")
	public String getRecipient() {
		return recipient;
	}
	public void setRecipient(String recipient) {
		this.recipient = recipient;
	}
	
	@Column(name="APPROVED")
	public String getApproved() {
		return approved;
	}
	public void setApproved(String approved) {
		this.approved = approved;
	}
	
	@Column(name="UNDERTAKE")
	public String getUndertake() {
		return undertake;
	}
	public void setUndertake(String undertake) {
		this.undertake = undertake;
	}
	
	@Column(name="ANNEX")
	public String getAnnex() {
		return annex;
	}
	public void setAnnex(String annex) {
		this.annex = annex;
	}
	
	@Column(name="REMARK")
	public String getRemark() {
		return remark;
	}
	public void setRemark(String remark) {
		this.remark = remark;
	}
	
	@OneToOne(cascade = CascadeType.ALL, fetch = FetchType.LAZY, optional = true)
	@JoinColumn(name="DEPID")
	public Department getDepartment() {
		return department;
	}
	public void setDepartment(Department department) {
		this.department = department;
	}
}
